<?php
/**
 * +----------------------------------------------------------------------
 * | summer framework
 * +----------------------------------------------------------------------
 * | Copyright (c) 2020 https://github.com/suframe/think-admin All rights reserved.
 * +----------------------------------------------------------------------
 * | Author: summer <806115620@qq.com>  2020/3/30 14:30
 * +----------------------------------------------------------------------
 */
declare (strict_types=1);

namespace app\mall\model\traits;

use app\mall\enum\FreightEnum;
use app\mall\enum\StatusEnum;
use think\Model;

/**
 * DateTrait
 * trait DateTrait
 * @package app\mall\model\traits
 * @property string $create_time
 * @mixin Model
 */
trait DateTrait
{

    /**
     * 获取发货类型名称
     * @param $key
     * @param $data
     * @return string
     */
    public function getCreateDateAttr($key, $data): string
    {
        return substr($this->create_time, 0, 10);
    }


}